#pragma once

#include<iostream>
#include<unordered_map>
#include<string>

#define SUCCESS 0
#define WARNING 1
#define FATAL 2


void initlog(std::unordered_map<int,std::string>& log)
{
    log.insert(std::make_pair(0,"SUCCESS"));
    log.insert(std::make_pair(1,"WARNING"));
    log.insert(std::make_pair(2,"FATAL"));
}

void logMessage(int grade)
{
    std::unordered_map<int,std::string> log;

    initlog(log);

    if(log.find(grade) != log.end())
    std::cout << log.find(grade) -> second << std::endl;
    else
    std::cout << "default errno" << std::endl;
}